<?php

class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
{
	protected function _initDoctype()
	{
		$this->bootstrap('view');
		$view = $this->getResource('view');
		$view->doctype('XHTML1_STRICT');
	}
    /**
     * Bootstrap autoloader for application resources
     * 
     * @return Zend_Application_Module_Autoloader
     */
    protected function _initAutoload()
    {
        $autoloader = new Zend_Application_Module_Autoloader(array(
            'namespace' => 'Application_',
            'basePath'  => APPLICATION_PATH
        ));
        
        return $autoloader;
    }
        /**
     * Creates a response object, sets the Content-Type header and assigns the
     * response to the front controller.
     *
     * @return null
     */
    protected function _initResponseCharset()
    {
        $front = Zend_Controller_Front::getInstance();
        $response = new Zend_Controller_Response_Http;
        $response->setHeader('Content-Type', 'text/html; charset=utf-8', false);
        $front->setResponse($response);
    }
    
        /**
     * Modify Routing.  Instead of the default routing this application will
     * accept a recipient name in place of the action method in the url.
     * For example: http://somesite.com/contact/Obi-Wan.Kenobi will route to the
     * default module > index controller > index action method with a recipient
     * parameter to which the recipient name is assigned.  The index controller
     * handles the decision as to whether the url contains an action method,
     * a valid recipient or something else.
     *
     * @return null
     */
//    protected function _initRouter()
//    {
//        $controller = Zend_Controller_Front::getInstance();
//        $router = $controller->getRouter();
//
//        $routes = array(
//            'default' => new Zend_Controller_Router_Route(
//                '/:action',
//                array(
//                    'controller' => 'index',
//                    'action'     => 'index',
//                    'module'     => 'default',
//                )
//            )
//        );
//
//        $router->addRoutes($routes);
//    }

    
}

